<?php
$this->breadcrumbs = array(
    'Assessment Report' => array('/AssesmentReport'),
    'Assessmentreport',
);

?>
<h1>
<?php echo $this->id . '/' . $this->action->id; ?></h1>
<br><br>
<?php
$employee = $dataReport['employee'];
?>
<table WIDTH="100%">
<tr>
	<td rowspan="6"><?php echo $employee['FIRST_NAME'] . " " . $employee["LAST_NAME"]?></td>
</tr>
<tr>
	<td colspan="4"><?php echo $employee['FIRST_NAME'] . " " . $employee["LAST_NAME"]?></td>
</tr>
<tr>
	<td colspan="4"><?php echo $employee["job_title_name"]?></td>
</tr>
<tr>
	<td>Work</td>
	<td><?php echo $employee["WORK_PHONE_NUMBER"]?></td>
	<td>Location</td>
	<td><?php echo $employee["CURRENT_WORK_LOCATION"]?></td>
</tr>
<tr>
	<td>Mobile</td>
	<td><?php echo $employee["MOBILE_NUMBER"]?></td>
	<td>Email</td>
	<td><?php echo $employee["EMAIL"]?></td>
</tr>
<tr>
	<td>Department</td>
	<td><?php echo $employee["org_name"]?></td>
	<td>Immediate Supervision</td>
	<td><?php echo ''?></td>
</tr>
<tr>
	<td>Developmental Title</td>
	<td><?php echo $employee["DEVELOPMENT_TITLE"]?></td>
	<td>Grade</td>
	<td><?php echo ''?></td>
</tr>
</table>
<table class="items">
		<tr>
			<th>COMP UNIT NAME</th>
			<th>COMP ELEM NAME</th>
			<th>COMP LIB NAME</th>
			<th>COMP LIB CODE</th>
			<th>LEVEL</th>
		</tr>
	<tbody>		
<?php 

foreach($dataReport["report"] as $i=>$row)
{
	$chart = array(
				array(array($row['level_passed'],$i)), 
				array(array($row['jlr'],$i)), 
			);

	echo '
		<tr>
			<td>'.$row['comp_unit_name'].'</td>
			<td>'.$row['comp_elem_name'].'</td>
			<td>'.$row['comp_lib_name'].'</td>
			<td>'.$i.'</td>
			<td>';
	$this->widget('application.extensions.jqplot.JqplotGraphWidget', 
		array(
			'data'=>$chart,
			'options'=>array(
					'seriesColors'=>array($row['color'],'lightblue'),
					'seriesDefaults'=>array(
						'renderer'=>'js:$.jqplot.BarRenderer',
						'rendererOptions'=>array('barDirection'=>'horizontal', 'barMargin'=>1, 'barPadding'=>1),
						'shadow'=>false,
					),
					'axes'=>array(
						'yaxis'=>array(
							'renderer'=>'js:$.jqplot.CategoryAxisRenderer',
							'min'=> 0,
							'show'=>false
						),

						'xaxis'=>array(
							'min'=> 0,
							'max'=>4,
							'numberTicks'=>5
						),
					),
			),
			'htmlOptions'=>array(
				   'style'=>'width:200px;height:50px;'
			),
			'pluginScriptFile'=>array(
				'jqplot.pointLabels.js',
				'jqplot.barRenderer.js',
				'jqplot.categoryAxisRenderer.js')
		)
	);

	echo '</td>
		</tr>			
	';
	
}
?>
	</tbody>
</table>
<?php
/*
$this->widget('application.extensions.jqplot.JqplotGraphWidget', 
    array(
        'data'=>$data,
        'options'=>array(
                'seriesDefaults'=>array(
                    'renderer'=>'js:$.jqplot.BarRenderer',
                    'rendererOptions'=>array('barDirection'=>'horizontal'),
					//'shadowAngle'=>0,
                ),
                'axes'=>array(
                    'yaxis'=>array(
						'renderer'=>'js:$.jqplot.CategoryAxisRenderer',
						'min'=> 0,
					),

					'xaxis'=>array(
						'min'=> 0,
						'max'=>4,
						'numberTicks'=>5
					),
                ),
        ),
        'htmlOptions'=>array(
               'style'=>'width:200px;height:100px;'
        ),
        'pluginScriptFile'=>array(
            //'jqplot.dateAxisRenderer.js',
            'jqplot.pointLabels.js',
            'jqplot.barRenderer.js',
            'jqplot.categoryAxisRenderer.js')
    )
);

*/
?>